Public methods for infoMessage.c. More...
#include "header.h"Data Structures | |
| struct | infoMessage |
Defines | |
| #define | MAX_PARAMETERS_IN_INFO_MESSAGE 17 |
| #define | INFO_MESSAGE_CLUSTER 0x0007 |
| #define | INFO_MESSAGE_VERSION 0x02 |
| #define | INFO_MESSAGE_FLAGS_NONE 0x00 |
| #define | DEVICETYPE_SMITH_ELECTRONCS_ROUTER_DEMO 0x01 |
| #define | DEVICESUBTYPE_SMITH_ELECTRONCS_ROUTER_DEMO 0x01 |
| #define | CAUSE_SCHEDULED 0x01 |
| #define | CAUSE_MOTION 0x02 |
| #define | CAUSE_STARTUP 0x03 |
Functions | |
| void | printInfoMessage (struct infoMessage *im) |
| void | serializeInfoMessage (struct infoMessage *im, unsigned char *destinationPtr) |
| struct infoMessage | deserializeInfoMessage (unsigned char *source) |
| unsigned int | getSizeOfInfoMessage (struct infoMessage *im) |
Public methods for infoMessage.c.
YOU ACKNOWLEDGE AND AGREE THAT THE SOFTWARE AND DOCUMENTATION ARE PROVIDED “AS IS” WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF MERCHANTABILITY, TITLE, NON-INFRINGEMENT AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL TEXAS INSTRUMENTS OR ITS LICENSORS BE LIABLE OR OBLIGATED UNDER CONTRACT, NEGLIGENCE, STRICT LIABILITY, CONTRIBUTION, BREACH OF WARRANTY, OR OTHER LEGAL EQUITABLE THEORY ANY DIRECT OR INDIRECT DAMAGES OR EXPENSES INCLUDING BUT NOT LIMITED TO ANY INCIDENTAL, SPECIAL, INDIRECT, PUNITIVE OR CONSEQUENTIAL DAMAGES, LOST PROFITS OR LOST DATA, COST OF PROCUREMENT OF SUBSTITUTE GOODS, TECHNOLOGY, SERVICES, OR ANY CLAIMS BY THIRD PARTIES (INCLUDING BUT NOT LIMITED TO ANY DEFENSE THEREOF), OR OTHER SIMILAR COSTS.
| #define MAX_PARAMETERS_IN_INFO_MESSAGE 17 |
INFO MESSAGE FROM: Device TO: Server RESPONSE: none
Contains device information, like manufacturer, model, etc.
| struct infoMessage deserializeInfoMessage | ( | unsigned char * | source | ) | [read] |
Creates an infoMessage from the stream of bytes starting at source
| source | the beginning of the serialized Info Message |
Check that numParameters < MAX_PARAMETERS_IN_INFO_MESSAGE
Point source to length field, and verify if length field == (sourcePtr - source)?
| unsigned int getSizeOfInfoMessage | ( | struct infoMessage * | im | ) |
| void printInfoMessage | ( | struct infoMessage * | im | ) |
Display the contents of the infoMessage to console
| im | the Info Message to display |
| void serializeInfoMessage | ( | struct infoMessage * | im, | |
| unsigned char * | destinationPtr | |||
| ) |
Outputs the info message as a stream of bytes to memory pointed to by destinationPtr Number of bytes streamed is equal to getSizeOfInfoMessage()
| im | the infoMessage to serialize | |
| destination | points to a region of memory at least getSizeOfInfoMessage() bytes in size |
1.6.3